public class UserOperationModel extends Object implements XMLMarshallable
Java class represents an audited user operation that has been processed and recorded by the SAP CC system; Your client application
can consult the operation results by implepement the handling of audits or by using the existing user interfaces to audit operations.
An audited user operation contains:
Notes
AuditModelThe XML APIs specify the following XSD fragment:
XSD Fragment
<xs:element name="userOperation">
<xs:complexType>
<xs:attribute name="reference" type="xs:long"/>
<xs:attribute name="operationName" type="xs:string"/>
<xs:attribute name="operatorName" type="xs:string" />
<xs:attribute name="operandReference" type="xs:string" />
<xs:attribute name="message" type="xs:string" default=""/>
<xs:attribute name="recordingDate" type="xs:dateTime"/>
</xs:complexType>
</xs:element>
| Modifier and Type | Field and Description |
|---|---|
static String |
RESULT_MESSAGE
The result message for a successful operation: "__RESULT__MESSAGE__"
|
| Constructor and Description |
|---|
UserOperationModel()
Creates an uninitialized user operation.
|
UserOperationModel(String operationName,
String operatorName,
String operandReference,
Date recordingDate)
Creates a user operation for a successful execution (no error message is specified).
|
UserOperationModel(String operationName,
String operatorName,
String operandReference,
String message,
Date recordingDate)
Creates a user operation for a failed execution (an error message is specified).
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCharacterData(String cData)
Adds character data to the content element.
|
void |
addChild(String tagname,
XMLMarshallable child)
Adds a child to the object, the
child representing
the marshallable object which must be added to the element. |
String |
getMessage()
Returns the message of the error.
|
String |
getOperandReference()
Returns the code or the reference (if no code exists) of the operand.
|
String |
getOperationName()
Returns the name of the operation executed.
|
String |
getOperatorName()
Returns the name of the operator (user login) which executed the operation.
|
Date |
getRecordingDate()
Returns the date when the operation was recorded by the system.
|
long |
getReference()
Returns the reference of the user operation (its unique identifier in the system).
|
void |
marshal(XMLOutputter output)
Gives an XML representation of this object, including its children.
|
void |
setAttributes(XMLAttributes atts)
Sets the attributes of the XML representation of the element being
processed.
|
void |
setMessage(String message)
Sets the message of the error.
|
void |
setOperandReference(String operandReference)
Sets the code or the reference (if no code exists) of the operand.
|
void |
setOperationName(String operationName)
Sets the name of the operation executed.
|
void |
setOperatorName(String operatorName)
Sets the name of the operator (user login) which executed the operation.
|
void |
setRecordingDate(Date recordingDate)
Sets the date when the operation was recorded by the system.
|
void |
setReference(long reference)
Sets the reference of the user operation (its unique identifier in the system).
|
public static final String RESULT_MESSAGE
public UserOperationModel()
public UserOperationModel(String operationName, String operatorName, String operandReference, Date recordingDate)
operationName - The name of the operation executedoperatorName - The name of the operator (user login) which executed the operationoperandReference - The code or the reference (if no code exists) of the operandrecordingDate - The date when the operation was recorded by the systempublic UserOperationModel(String operationName, String operatorName, String operandReference, String message, Date recordingDate)
operationName - The name of the operation executedoperatorName - The name of the operator (user login) which executed the operationoperandReference - The code or the reference (if no code exists) of the operandmessage - The code or the reference (if no code exists) of the operandrecordingDate - The date when the operation was recorded by the systempublic String getOperationName()
public void setOperationName(String operationName)
operationName - The name of the operation executedpublic String getOperatorName()
public void setOperatorName(String operatorName)
operatorName - The name of the operator (user login) which executed the operationpublic String getOperandReference()
public void setOperandReference(String operandReference)
operandReference - The code or the reference (if no code exists) of the operandpublic String getMessage()
public void setMessage(String message)
message - The message of the errorpublic Date getRecordingDate()
public void setRecordingDate(Date recordingDate)
recordingDate - The date when the operation was recorded by the systempublic long getReference()
public void setReference(long reference)
reference - The reference of the user operation (its unique identifier in the system)public void addChild(String tagname, XMLMarshallable child)
XMLMarshallablechild representing
the marshallable object which must be added to the element.addChild in interface XMLMarshallabletagname - The name of tag for the childchild - The child to be addedpublic void addCharacterData(String cData)
XMLMarshallableaddCharacterData in interface XMLMarshallablecData - The character data to be addedpublic void setAttributes(XMLAttributes atts)
XMLMarshallablesetAttributes in interface XMLMarshallableatts - The XML attributes of the current elementpublic void marshal(XMLOutputter output)
XMLMarshallablemarshal in interface XMLMarshallableoutput - The XML output to marshal the object into